Skip to content

Conversation

stuart-pebble
Copy link

This update enables users to specify a custom PostgreSQL schema for Flowise to use, improving database organization and multi-tenant deployments.

Changes:

  • Add schema property to PostgreSQL DataSource configuration using DATABASE_SCHEMA env var
  • Configure search_path to include custom schema, public, and extensions schemas
  • Ensure UUID functions remain accessible from extensions schema
  • Maintain backward compatibility with default 'public' schema when DATABASE_SCHEMA is not set

…onment variable

This update enables users to specify a custom PostgreSQL schema for Flowise to use,
improving database organization and multi-tenant deployments.

Changes:
- Add schema property to PostgreSQL DataSource configuration using DATABASE_SCHEMA env var
- Configure search_path to include custom schema, public, and extensions schemas
- Ensure UUID functions remain accessible from extensions schema
- Maintain backward compatibility with default 'public' schema when DATABASE_SCHEMA is not set

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
@HenryHengZJ
Copy link
Contributor

just curious, under what scenario and condition that you might want to use other schema other than public, and searchPath too? can you give me an example?

@stuart-pebble
Copy link
Author

stuart-pebble commented Jul 3, 2025 via email

@HenryHengZJ
Copy link
Contributor

faced with the error when setting to different schema:

2025-07-09 14:29:03 [ERROR]: ❌ [server]: Error during Data Source initialization: relation "UQ_6352078b5a294f2d22179ea7956" already exists
QueryFailedError: relation "UQ_6352078b5a294f2d22179ea7956" already exists

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants